{smcl}
{com}{sf}{ul off}{txt}{.-}
      name:  {res}<unnamed>
       {txt}log:  {res}C:\Users\k1466170\Documents\Great Reform riots\UK riots\Data\Parish Names\Hobsbawm\replication material - BJPolS\newspaper.smcl
  {txt}log type:  {res}smcl
 {txt}opened on:  {res} 9 Oct 2020, 12:14:26

{com}. do "C:\Users\k1466170\Documents\Great Reform riots\UK riots\Data\Parish Names\Hobsbawm\replication material - BJPolS\newspaper distribution.do"
{txt}
{com}. 
. ************************************************************************
. * Replication material for "The role of structural factors and         *
. * diffusion in social unrest: evidence from the Swing Riots"  *
. *                                                                      *
. * Aidt and Leon (2020)                                                 *
. ************************************************************************
. 
. 
. ********************************************************
. * This file produces Figure A1 in the online appendix: *
. * "Distribution of distances to newspapers"            *
. ********************************************************
. 
. clear
{txt}
{com}. sysdir set PERSONAL "C:\Users\k1466170\Documents\ado"
{txt}
{com}. sysdir set PLUS "C:\Users\k1466170\Documents\ado"
{txt}
{com}. 
. * Delete or change the following as appropriate:
. cd "C:\Users\k1466170\Documents\Great Reform riots\UK riots\Data\Parish Names\Hobsbawm\replication material - BJPolS"
{res}C:\Users\k1466170\Documents\Great Reform riots\UK riots\Data\Parish Names\Hobsbawm\replication material - BJPolS
{txt}
{com}. 
. use "newspaper_distribution.dta"
{txt}
{com}. 
. * Set plotting scheme
. set scheme plotplainblind
{txt}
{com}. 
. twoway kdensity news_dist if allriotsX==1, lpattern(dash)  || kdensity news_dist if allriotsX>0
{res}{txt}
{com}. 
. 
. kdensity news_dist, nograph generate(x fx)
{txt}
{com}. kdensity news_dist if allriotsX==0, nograph generate(fx0) at(x)
{txt}
{com}. kdensity news_dist if allriotsX>1, nograph generate(fx1) at(x)
{txt}
{com}. label var fx0 "no riots"
{txt}
{com}. label var fx1 "riots"
{txt}
{com}. line fx0 fx1 x, sort ytitle(Density) xtitle(Distance to nearest newspaper)
{res}{txt}
{com}. 
{txt}end of do-file

{com}. log close
      {txt}name:  {res}<unnamed>
       {txt}log:  {res}C:\Users\k1466170\Documents\Great Reform riots\UK riots\Data\Parish Names\Hobsbawm\replication material - BJPolS\newspaper.smcl
  {txt}log type:  {res}smcl
 {txt}closed on:  {res} 9 Oct 2020, 12:14:44
{txt}{.-}
{smcl}
{txt}{sf}{ul off}